package com.nCoV.EpidemicSurveillance.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * @author 罗穆健
 * @date 2020年3月3日
 */
@Configuration
public class SpringMvcConfig implements WebMvcConfigurer {

    @Override
    public void addViewControllers(ViewControllerRegistry registry) {
        registry.addViewController("/index").setViewName("noLoginRequired/index");
        registry.addViewController("/").setViewName("noLoginRequired/index");
        registry.addViewController("/entry").setViewName("data_entry");
        registry.addViewController("/userMsg").setViewName("noLoginRequired/user_information");
        registry.addViewController("/Login").setViewName("Login");
        registry.addViewController("/userArea").setViewName("noLoginRequired/userArea");
        registry.addViewController("/entry/userInformation").setViewName("userInformation");
    }
}